{* Smarty *}
{*
 *  This file is part of Urd.
 *
 *  Urd is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 3 of the License, or
 *  (at your option) any later version.
 *  Urd is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program. See the file "COPYING". If it does not
 *  exist, see <http://www.gnu.org/licenses/>.
 *
 * $LastChangedDate: 2008-07-03 22:46:29 +0200 (Thu, 03 Jul 2008) $
 * $Rev: 1265 $
 * $Author: gavinspearhead $
 * $Id: admin_buttons.tpl 1265 2008-07-03 20:46:29Z gavinspearhead $
 *}

<div id="hideoverlay">
<img src="{$IMGDIR}/icon_cancel.png" class="buttonlike" alt="Close" title="Close" onclick="javascript:thisdiv=document.getElementById('buttoneditdiv'); ToggleClass(thisdiv, 'editbuttonoff'); ToggleClass(thisdiv,'editbuttonon');"/>
</div>

<h2>{if $id eq 'new'}{$LN_buttons_addbutton}{else}{$LN_buttons_editbutton}{/if}</h2>
<div>
<input type="hidden" name="challenge" id="challenge_editbuttons" value="{$challenge}"/>
<input type="hidden" name="id" id="id" value="{$id}"/>
</div>

<table>
<tr>
<td>{$LN_buttons_name}</td>
<td><input type="text" name="name" id="name" value="{$button->name|escape}" size="{$text_box_size}"/></td>
</tr>
<tr>
<td>{$LN_buttons_url}</td>
<td><input type="text" name="search_url" id="search_url" value="{$button->url|escape}" size="{$text_box_size}"/></td>
</tr>
<tr>
<td>{$LN_buttons_image}</td>
<td><input type="text" name="image_url" id="image_url" value="{$button->img|escape}" size="{$text_box_size}"/></td>
</tr>
<tr><td>&nbsp;</td><td>&nbsp;</td></tr>
<tr>
{if $id eq 'new'}
	<td><input type="submit" name="add" value="{$LN_add}" class="submit" onclick="javascript:update_buttons();"/></td>
{else}
	<td><input type="submit" value="{$LN_apply}" name="apply" class="submit" onclick="javascript:update_buttons();"/>
	<input type="hidden" name="id" value="{$buttons[x]->id}"/></td>
{/if}

</tr>
